package svc

import (
	"baidu/api/internal/config"
	"baidu/baidurpc/baidurpcclient"
	"github.com/zeromicro/go-zero/zrpc"
)

type ServiceContext struct {
	Config config.Config
	BaiDu  baidurpcclient.Baidurpc
}

func NewServiceContext(c config.Config) *ServiceContext {
	return &ServiceContext{
		Config: c,
		BaiDu:  baidurpcclient.NewBaidurpc(zrpc.MustNewClient(c.BaiDu)),
	}
}
